﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input;
using Microsoft.Xna.Framework.Storage;
using Microsoft.Xna.Framework.GamerServices;

namespace Tenebrous_Manor
{
    class Map
    {
        int[,] map;
        String fileName;
        Vector2 tileSize;
        Texture2D textureTile;
        int rowCount;
        int colCount;

        SpriteFont font;

        public Map(int[,] map, Texture2D textureTile, Vector2 tileSize, SpriteFont font)
        {
            this.map = map;
            this.tileSize = tileSize;
            this.textureTile = textureTile;
            this.font = font;

            rowCount = (int)Math.Sqrt(map.Length);
            colCount = (int)Math.Sqrt(map.Length);
        }

        public void Draw(SpriteBatch spriteBatch)
        {
            for (int row = 0; row < rowCount; row++)
            {
                for (int col = 0; col < colCount; col++)
                {
                    spriteBatch.Draw(textureTile, new Vector2(tileSize.X * col, tileSize.Y * row), Color.White);
                }
            }
            
        }

    }

}
